#ifndef DEVICE_HPP
#define DEVICE_HPP


#include <string>
#include <memory>

#include <boost/cstdint.hpp>
#include <boost/scoped_ptr.hpp>

namespace kieper {
    class DeviceSpecInfo;
    class ConnMgr;
    class IncomingPacket;
    class Message;
    
    typedef std::auto_ptr<IncomingPacket> IncomingPacketPtr;
    class Device {
    public:
        Device(uint16_t id, std::string desc, ConnMgr* connMgr, DeviceSpecInfo* deviceInfo=NULL);
        ~Device();
        IncomingPacketPtr sendSyncMsg(const Message& message);
        const DeviceSpecInfo* getDeviceInfo() const;
    protected:
    private:
        uint16_t id_;
        Device& operator=(const Device& other);
        /**
         * Device description
         */
        std::string desc_;
        ConnMgr* connMgr_;
        boost::scoped_ptr<DeviceSpecInfo> deviceInfo_;
    };
}

#endif
